-
-
Notifications
You must be signed in to change notification settings - Fork 6k
Remove deprecated auth sources #35272
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove deprecated auth sources #35272
Conversation
Entra ID users should use the OIDC oauth2 provider
|
||
for _, provider := range gothProviders { | ||
if slices.Contains(azureProviders, provider.Name()) && !slices.Contains(existAuthSources, provider.Name()) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Isn't that an gothProviders = gothProviders.Remove(existingAzureSources)
?
(Although it will probably look different since the stdlib doesn't seem to support that method…)
authSources, err := db.Find[auth.Source](ctx, auth.FindSourcesOptions{ | ||
LoginType: auth.OAuth2, | ||
}) | ||
if err != nil { | ||
return nil | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It shouldn't silently ignore an unknown error.
…itea into techknowlogick-deprecate-azure-ad-auth
func GetSupportedOAuth2Providers() []Provider { | ||
return GetSupportedOAuth2ProvidersWithContext(context.Background()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In most cases, context.Background
shouldn't be used
-> Fix context usages #35348
* giteaofficial/main: Prevent duplicate actions email (go-gitea#35215) rename nightly docker tag for main branch (go-gitea#35344) Fix atom/rss mixed error (go-gitea#35345) Remove deprecated auth sources (go-gitea#35272) Always return the relevant status information, even if no status exists. (go-gitea#35335) [skip ci] Updated translations via Crowdin Upgrade mermaid from 11.9.0 to 11.10.0 (go-gitea#35329) Use configurable remote name for git commands (go-gitea#35172)
Entra ID users should use the OIDC oauth2 provider.
They will still be shown if the instance has a previous Azure AD source configured.